BOTTOM_RECORDS Function
Syntax
Arguments
- Filter_Expression
A character filter expression that selects records from a table. Numeric
- count
A positive number. Numeric
- filter
Optional. A character filter expression that selects records from a table. Character
Description
Return the bottom 'count' records for a given sort order.
Discussion
BOTTOM_RECORDS() is a special function used only in queries to return the bottom Quantity of records in a table for a given sort order. If the optional filter is supplied, only the records selected by the filter are returned. Note : The term "bottom" does not imply that record values are examined. "Bottom" means last, given the current sort order.
Example
See Record Sampling Functions for more information. 'The following query returns the bottom 10 orders placed after 'May 1, 2000.
dim tbl as P dim inx as P tbl = table.current() query.filter = "bottom_records(10, \"orderdate > {5/1/2000}\")" query.order = "order_total" inx = tbl.query_create() topparent.resynch()
See Also